package com.fengniu.ejb.entity;

import java.io.Serializable;
import java.util.Date;

import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.EntityListeners;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Inheritance;
import javax.persistence.InheritanceType;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

import com.fengniu.ejb.entity.callback.GeneEntityCallbackListener;

//@MappedSuperclass
//public abstract  class GeneEntity implements Serializable {
@Entity
@Inheritance(strategy = InheritanceType.TABLE_PER_CLASS)
@EntityListeners(GeneEntityCallbackListener.class)
public class GeneEntity implements Serializable {

	/**
	 * 
	 */
	private static final long serialVersionUID = -168544564797933101L;

	@Id
	@GeneratedValue(strategy = GenerationType.AUTO)
	private Long sysId;

	@Basic(fetch = FetchType.LAZY)
	@Column(length = 10240)
	private String shortDesc;

	@Basic(fetch = FetchType.LAZY)
	@Column(length = 30720)
	private String longDesc;

	@Temporal(value = TemporalType.TIMESTAMP)
	private Date createdDate;

	@Temporal(value = TemporalType.TIMESTAMP)
	private Date lastUpdatedDate;

	private Integer status;

	private Integer typeId;

	public Date getCreatedDate() {
		return createdDate;
	}

	public void setCreatedDate(Date createdDate) {
		this.createdDate = createdDate;
	}

	public Date getLastUpdatedDate() {
		return lastUpdatedDate;
	}

	public void setLastUpdatedDate(Date lastUpdatedDate) {
		this.lastUpdatedDate = lastUpdatedDate;
	}

	public Long getSysId() {
		return sysId;
	}

	public void setSysId(Long sysId) {
		this.sysId = sysId;
	}

	public String getLongDesc() {
		return longDesc;
	}

	public void setLongDesc(String description) {
		this.longDesc = description;
	}

	public String getShortDesc() {
		return shortDesc;
	}

	public void setShortDesc(String shortDesc) {
		this.shortDesc = shortDesc;
	}

	public Integer getStatus() {
		return status;
	}

	public void setStatus(Integer status) {
		this.status = status;
	}

	public Integer getTypeId() {
		return typeId;
	}

	public void setTypeId(Integer typeId) {
		this.typeId = typeId;
	}

}
